/*    */ package com.Ticker.tokens;
/*    */ 
/*    */ import net.ledticker.elements.ColorModel;
/*    */ import net.ledticker.elements.Token;
/*    */ 
/*    */ public class TextToken extends Token
/*    */ {
/*    */   private String text;
/*    */ 
/*    */   public TextToken()
/*    */   {
/* 21 */     this("");
/*    */   }
/*    */ 
/*    */   public TextToken(String text)
/*    */   {
/* 28 */     this(text, null);
/*    */   }
/*    */ 
/*    */   public TextToken(String text, ColorModel colorModel)
/*    */   {
/* 37 */     super(colorModel);
/* 38 */     this.text = text;
/*    */   }
/*    */ 
/*    */   public String getDisplayValue()
/*    */   {
/* 45 */     return this.text;
/*    */   }
/*    */ 
/*    */   public void setValue(Object value)
/*    */   {
/* 52 */     if (value == null) {
/* 53 */       throw new NullPointerException("Given value cannot be null");
/*    */     }
/* 55 */     if (value instanceof String) {
/* 56 */       this.text = ((String)value);
/* 57 */       return;
/*    */     }
/*    */ 
/* 60 */     throw new IllegalArgumentException("Given value must be a String, not " + value.getClass().getName());
/*    */   }
/*    */ }

/* Location:           C:\Users\os\Downloads\TrimOnline.jar
 * Qualified Name:     Ticker.tokens.TextToken
 * JD-Core Version:    0.5.4
 */